import {InterfaceUser} from '@/interface/InterfaceUser';

export default class UserEntity {
    private readonly originalData: InterfaceUser;

    public constructor(arg: InterfaceUser) {

        this.originalData = arg;
    }

    public get getBaseInfo(): any {
        return {
            nickName: this.originalData.nickname,
            avatar_id: this.originalData.avatarId,
            birthday: this.originalData.birthday,
            gender: this.originalData.gender,
            province_id: this.originalData.provinceId,
            snap_province_id: this.originalData.snapProvinceId,
            city_id: this.originalData.cityId,
            snap_city_id: this.originalData.snapCityId,
            district_id: this.originalData.districtId,
            snap_district_id: this.originalData.snapDistrictId,
            HEIGHT: this.originalData.height,
            SNAP_HEIGHT: this.originalData.snapHeight,
            INCOME: this.originalData.income,
            SNAP_INCOME: this.originalData.snapIncome,
            EDUCATION: this.originalData.education,
            SNAP_EDUCATION: this.originalData.snapEducation,
            MARITAL_STATUS: this.originalData.maritalStatus,
            SNAP_MARITAL_STATUS: this.originalData.snapMaritalStatus,
            CHILD: this.originalData.child,
            SNAP_CHILD: this.originalData.snapChild,
            HOUSE_PURCHASE: this.originalData.height,
            SNAP_HOUSE_PURCHASE: this.originalData.snapHousePurchase,
            CAR_PURCHASE: this.originalData.carPurchase,
            SNAP_CAR_PURCHASE: this.originalData.snapCarPurchase,
        };
    }

    public get getBaseInfoExcludeSex(): any {
        const baseInfo: any = this.getBaseInfo;
        delete baseInfo.gender;
        return baseInfo;
    }

    public get getArchives(): any {
        return {
            HOMETOWN_PROVINCE_ID: this.originalData.hometownProvinceId,
            SNAP_HOMETOWN_PROVINCE_ID: this.originalData.snapHometownProvinceId,
            HOMETOWN_CITY_ID: this.originalData.hometownCityId,
            SNAP_HOMETOWN_CITY_ID: this.originalData.snapHometownCityId,
            REGISTERED_RESIDENCE_PROVINCE_ID: this.originalData.registeredResidenceProvinceId,
            SNAP_REGISTERED_RESIDENCE_PROVINCE_ID: this.originalData.snapRegisteredResidenceProvinceId,
            REGISTERED_RESIDENCE_CITY_ID: this.originalData.registeredResidenceCityId,
            SNAP_REGISTERED_RESIDENCE_CITY_ID: this.originalData.snapRegisteredResidenceCityId,
            NATION: this.originalData.nation,
            SNAP_NATION: this.originalData.snapNation,
            ZODIAC: this.originalData.zodiac,
            SNAP_ZODIAC: this.originalData.snapZodiac,
            CONSTELLATION: this.originalData.constellation,
            SNAP_CONSTELLATION: this.originalData.snapConstellation,
            BLOODTYPE: this.originalData.bloodtype,
            SNAP_BLOODTYPE: this.originalData.snapBloodtype,
            SHARE: this.originalData.share,
            SNAP_SHARE: this.originalData.snapShare,
            WEIGHT: this.originalData.weight,
            SNAP_WEIGHT: this.originalData.snapWeight,
            EVALUATION: this.originalData.evaluation,
            SNAP_EVALUATION: this.originalData.snapEvaluation,
            BELIEF: this.originalData.belief,
            SNAP_BELIEF: this.originalData.snapBelief,
            SMOKE: this.originalData.smoke,
            SNAP_SMOKE: this.originalData.snapSmoke,
            DRINK: this.originalData.drink,
            SNAP_DRINK: this.originalData.snapDrink,
            DAILYLIFE: this.originalData.dailylife,
            SNAP_DAILYLIFE: this.originalData.snapDailylife
        };
    }

    public get getEducationWork(): any {
        return {
            UNIVERSITY: this.originalData.university,
            SNAP_UNIVERSITY: this.originalData.snapUniversity,
            MAJOR: this.originalData.major,
            SNAP_MAJOR: this.originalData.snapMajor,
            DUTIES: this.originalData.duties,
            SNAP_DUTIES: this.originalData.snapDuties,
            COMPANY_NATURE: this.originalData.companyNature,
            SNAP_COMPANY_NATURE: this.originalData.snapCompanyNature,
            COMPANY_INDUSTRY: this.originalData.companyIndustry,
            SNAP_COMPANY_INDUSTRY: this.originalData.snapCompanyIndustry,
            WORKING_CONDITION: this.originalData.workingCondition,
            SNAP_WORKING_CONDITION: this.originalData.snapWorkingCondition,
            MASTER_LANGUAGE: this.originalData.masterLanguage,
            SNAP_MASTER_LANGUAGE: this.originalData.snapMasterLanguage,
        };
    }

    public get getFamilyCondition(): any {
        return {
            FAMILY_RANKING: this.originalData.familyRanking,
            SNAP_FAMILY_RANKING: this.originalData.snapFamilyRanking,
            PARENT_SITUATION: this.originalData.parentSituation,
            SNAP_PARENT_SITUATION: this.originalData.snapParentSituation,
            FATHER_WORK: this.originalData.fatherWork,
            SNAP_FATHER_WORK: this.originalData.snapFatherWork,
            MOTHER_WORK: this.originalData.motherWork,
            SNAP_MOTHER_WORK: this.originalData.snapMotherWork,
            PARENT_ECONOMY: this.originalData.parentEconomy,
            SNAP_PARENT_ECONOMY: this.originalData.snapParentEconomy,
            PARENTAL_INSURANCE: this.originalData.parentalInsurance,
            SNAP_PARENTAL_INSURANCE: this.originalData.snapParentalInsurance,

        };
    }

    public get getLovePlanning(): any {
        return {
            MARRIAGE_TIME: this.originalData.marriageTime,
            SNAP_MARRIAGE_TIME: this.originalData.snapMarriageTime,
            DATING_STYLE: this.originalData.datingStyle,
            SNAP_DATING_STYLE: this.originalData.snapDatingStyle,
            OTHER_SIDE_VALUES: this.originalData.otherSideValues,
            SNAP_OTHER_SIDE_VALUES: this.originalData.snapOtherSideValues,
            WEDDING_FORM: this.originalData.weddingForm,
            SNAP_WEDDING_FORM: this.originalData.snapWeddingForm,
            LIVING_WITH_PARENTS: this.originalData.livingWithParents,
            SNAP_LIVING_WITH_PARENTS: this.originalData.snapLivingWithParents,
            WANT_CHILDREN: this.originalData.wantChildren,
            SNAP_WANT_CHILDREN: this.originalData.snapWantChildren,
            COOKING_CONDITION: this.originalData.cookingCondition,
            SNAP_COOKING_CONDITION: this.originalData.snapCookingCondition,
            DIVISION_OF_LABOUR: this.originalData.divisionOfLabour,
            SNAP_DIVISION_OF_LABOUR: this.originalData.snapDivisionOfLabour,
        };
    }

    public get getMateSelection(): any {
        return {
            mate_age: this.originalData.mateSelection.age,
            snap_mate_age: this.originalData.mateSelection.snapAge,
            mate_height: this.originalData.mateSelection.height,
            snap_mate_height: this.originalData.mateSelection.snapHeight,
            mate_education: this.originalData.mateSelection.education,
            snap_mate_education: this.originalData.mateSelection.snapEducation,
            mate_income: this.originalData.mateSelection.income,
            snap_mate_income: this.originalData.mateSelection.snapIncome,
            mate_province: this.originalData.mateSelection.provinceId,
            snap_mate_province: this.originalData.mateSelection.snapProvinceId,
            mate_city: this.originalData.mateSelection.cityId,
            snap_mate_city: this.originalData.mateSelection.snapCityId,
            mate_marital: this.originalData.mateSelection.maritalStatus,
            snap_mate_marital: this.originalData.mateSelection.snapMaritalStatus,
            mate_housing: this.originalData.mateSelection.housePurchase,
            snap_mate_housing: this.originalData.mateSelection.snapHousePurchase,
            mate_child: this.originalData.mateSelection.child,
            snap_mate_child: this.originalData.mateSelection.snapChild,
        };
    }

    public get getMatchmakerBaseInfo(): any {
        return {
            nickName: this.originalData.nickname,
            avatar_id: this.originalData.avatarId,
            birthday: this.originalData.birthday,
            gender: this.originalData.gender,
            province_id: this.originalData.provinceId,
            snap_province_id: this.originalData.snapProvinceId,
            city_id: this.originalData.cityId,
            snap_city_id: this.originalData.snapCityId,
            district_id: this.originalData.districtId,
            snap_district_id: this.originalData.snapDistrictId,
            industry: this.originalData.industry,
            snap_industry: this.originalData.snapIndustry,
            company_position: this.originalData.companyPosition,
            identity_introduction: this.originalData.identityIntroduction,
        };
    }
}
